<%@ page language="java" contentType="text/html; charset=utf-8"
	pageEncoding="utf-8" isELIgnored="false"%>
<%@ include file="/WEB-INF/views/shared/taglib.jsp"%>
<div class="row">
	<div class="col-md-12 col-sm-12 col-lg-12 col-xs-12 text-right">
		<t-auth:roleButton />
	</div>
</div>
<script type="text/javascript">

function selData(){
	var recordType=$(".cntable.table>tbody>tr.select-tr").attr("data-recordType");
	var key=getKeyId();
	if(isEditor(key)){
		switch(recordType)
    	{
    	case "采购退货":
    		top.openModal("/purchase/returnPurchase/selInStock?key="+key,"purpose_form","采购退货记录",1100,476);
    	  break;
    	case "入库":
    		top.openModal("/purchase/purchase/selInStock?key="+key,"purpose_form","入库记录",1100,476);
    	  break;
    	case "出库":
    		top.openModal("/stock/outStock/detailed?key="+key+"&type="+"check","outStock_form","出库详情-查看",1100,500);
    	  break;
	    case "发货":
	    	top.openModal("/stock/outStock/detailed?key="+key+"&type="+"check","outStock_form","发货详情-查看",1100,500);
		  break;
	    case "退货":
	    	top.openModal("/stock/outStock/detailed?key="+key+"&type="+"check","outStock_form","退货详情-查看",1100,500);
		  break;
	    case "盘点":
	    	top.openModal("/stock/inventory/selDetailed?key="+key+"&type="+"check","stock_form","盘点详情-查看",1100,550);
		  break;
	    case "调整":
	    	top.openModal("/stock/inventory/selDetailed?key="+key+"&type="+"check","stock_form","调整详情-查看",1100,550);
		  break;
		}
	}
}


function exportData(){
	var url=$.getVirtualPath()+"/stock/stock/exportExcel";
	var data=$("form:first").serialize();
	var cachedId=$.getText(url,data);
	downloadExcel(cachedId);
}
</script>
<%@ include file="/WEB-INF/views/shared/base/scripts/limitless/default/notifications.jsp"%>
